package xyz.longicorn.driver.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import xyz.longicorn.driver.service.RabbitMQService;

import javax.annotation.Resource;

@RestController
public class MessageQueueController {

    @Resource
    private RabbitMQService rabbitMQService;

    @RequestMapping("/send-msg")
    public String sendMessage(String message) {
        rabbitMQService.sendMessage(message);
        return "send message success";
    }
}
